#include <bits/stdc++.h>
#define ll long long
using namespace std;

template<typename ...Args>
signed debug(const char*str,Args&&...args){return fprintf(stderr,str,args...);}

inline static int read(){
    int sum=0,neg=false,ch=getchar();
    while(!isdigit(ch)) neg|=(ch=='-'),ch=getchar();
    while(isdigit(ch)) sum=sum*10+(ch^48),ch=getchar();
    return neg?-sum:sum;
}

char str[10005],Map[105][105];
signed main(){
    freopen("snake.in","r",stdin);
    freopen("snake.out","w",stdout);
    scanf("%s",str); int n=strlen(str);
    for(int i=1;i<=100;i++) memset(Map[i]+1,'R',100);
    for(int i=0,x=1,y=1;i<n;i++){
        Map[x][y]=str[i];
        y=x&1?y+1:y-1;
        if(y<1) x++,y=1;
        if(y>100) x++,y=100;
    }
    puts("100 100");
    for(int i=1;i<=100;i++) puts(Map[i]+1);
    puts("1 1");
    for(int i=2,x=1,y=1;i<=n;i++){
        if(++y>100) y=1,x++,putchar('D');
        else putchar(x&1?'R':'L');
    }
    return 0;
}
